import { Carousel } from 'antd'

import {torem} from '../../assets/js/rem'

function Swiper(props) {
  const data = props.data
  const baseURL = 'https://gw.alicdn.com/tfs/'
  
  return (
    <div>
      <Carousel autoplay>
        {data.map(i => <div key={i.id}><img style={{display: 'block',height: torem(150),width: '100%'}} src={baseURL + i.smallPicUrl} alt=''/></div>)}
      </Carousel>
    </div>
  )
}

export default Swiper